﻿using System;
using System.Collections.Generic;
using yiCommerce.Core.Domain.Brands;
using yiCommerce.Core.Domain.Categorys;
using yiCommerce.Core.Domain.Shops;

namespace yiCommerce.Core.Domain.Products
{
    public class Product:BaseEntity
    {
       

        public virtual int ShopId { get; set; }

        public virtual Shop Shop { get; set; }


        public virtual string ProductName { get; set; }

        public virtual string ShortDescription { get; set; }

        public virtual string FullDescription { get; set; }

        public virtual bool Published { get; set; }

        public virtual bool Deleted { get; set; }
    
        public virtual DateTime CreatedOnUtc { get; set; }

        public virtual DateTime UpdatedOnUtc { get; set; }



        private ICollection<ProductVariant> _productVariants;

        private ICollection<ProductPicture> _productPictures;

        private ICollection<ProductCategory> _productCategories;

        private ICollection<ProductBrand> _productBrands;

        private ICollection<ProductSpecificationAttribute> _productSpecificationAttributes;

        public virtual ICollection<ProductVariant> ProductVariants
        {
            get { return _productVariants ?? (_productVariants = new List<ProductVariant>()); }
            set { _productVariants = value; }
        }
        /// <summary>
        /// Gets or sets the collection of ProductCategory
        /// </summary>
        public virtual ICollection<ProductCategory> ProductCategories
        {
            get { return _productCategories ?? (_productCategories = new List<ProductCategory>()); }
            set { _productCategories = value; }
        }

        /// <summary>
        /// Gets or sets the collection of ProductManufacturer
        /// </summary>
        public virtual ICollection<ProductBrand> ProductBrands
        {
            get { return _productBrands ?? (_productBrands = new List<ProductBrand>()); }
            set { _productBrands = value; }
        }

        /// <summary>
        /// Gets or sets the collection of ProductPicture
        /// </summary>
        public virtual ICollection<ProductPicture> ProductPictures
        {
            get { return _productPictures ?? (_productPictures = new List<ProductPicture>()); }
            set { _productPictures = value; }
        }
        /// <summary>
        /// Gets or sets the product specification attribute
        /// </summary>
        public virtual ICollection<ProductSpecificationAttribute> ProductSpecificationAttributes
        {
            get { return _productSpecificationAttributes ?? (_productSpecificationAttributes = new List<ProductSpecificationAttribute>()); }
             set { _productSpecificationAttributes = value; }
        }

    }
}